Skip to main content

All Questions

6votes
2answers
232views

(HackerRank) Project Euler+ #250: 250250

Link to problem: linkNumber of solvers: 27 out of 844Solve rate (per person): 3.199%Success rate (over all submissions): 1.78% Project Euler+ on HackerRank is basically supposed to be a generalization ...
CrSb0001's user avatar
7votes
4answers
1kviews

LeetCode 977: Squares of a sorted array, maintaining non-decreasing order

I tried solving the LeetCode question like many others, trying to incorporate the O(n) time complexity requirement. Squares of a Sorted Array Given an integer array ...
Littlejacob2603's user avatar
5votes
1answer
226views

Performance Tuning to enable answer for Project Euler #566 "Cake Icing Puzzle"

Related to this question I am still looking for a solution to Project Euler Problem 566 (see link for a nice simulation also): Adam plays the following game with his birthday cake. He cuts a piece ...
DuesserBaest's user avatar
2votes
3answers
752views

Find median value of two Sorted Arrays

To improve my coding knowledge can you please give me suggested changes on my code? ...
Subha Rajagopal's user avatar
2votes
1answer
98views

HackerRank Algorithm Problem: Climbing the Leaderboard (Python)

Here is the Hackerrank problem which is related to dense ranking and below is my solution which didn't pass the time limit cases. Any better way to optimize this? ...
peternish's user avatar
3votes
2answers
318views

Trailing Digits

https://www.acmicpc.net/problem/23204 I've solved a programming challenge where you need to count the occurrences of a specific digit at the end of the product of multiples of a given number within a ...
qleoz12's user avatar
0votes
1answer
126views

HackerRank Project Euler 12 (Python) | Highly Divisible Triangular Numbers

I again share my Python code which didn't pass time limit test cases in the HackerRank contest of ProjectEuler. ...
peternish's user avatar
1vote
1answer
2kviews

sum of intervals kata in codewars

instructions for the kata: Write a function called sumIntervals/sum_intervals() that accepts an array of intervals, and returns the sum of all the interval lengths. Overlapping intervals should only ...
melike's user avatar
7votes
2answers
1kviews

Find all combinations of length 3 whose sum is divisible by a given number

I came up with a suitable solution to a HackerRank problem that failed because the execution took longer than 10 seconds on lists that were of very large size. The problem: Given a list ...
NFeruch - FreePalestine's user avatar
5votes
1answer
496views

Connecting ropes with minimum cost

Question: There are given N ropes of different lengths, we need to connect these ropes into one rope. The cost to connect two ropes is equal to sum of their lengths. The task is to connect the ropes ...
Sherlock-Holmes-2-2-1's user avatar
3votes
2answers
421views

Euler Project: Sums of Digit Factorials

MY CODE: ...
CaptainPotato's user avatar
1vote
2answers
123views

Sum of differences between products and LCMs

I've been trying to solve this Codewars problem https://www.codewars.com/kata/56e56756404bb1c950000992 In this kata you need to create a function that takes a 2D array/list of non-negative integer ...
post_lupy's user avatar
4votes
1answer
284views

Decibinary for xth number (Python code)

I created the code for the problem description below. It works for \$N\le10^6\$ but after that it gives a time out error. What I don't understand is how to optimize the code using dynamic programming. ...
vijayalakshmi_bhagat's user avatar
4votes
1answer
168views

Time limit error in 'The Minion Game' using python in Hacker Rank

This is the question link for the quick reference. Problem : There are two players Kevin and Stuart have to play a game in which they're pleased to create multiple strings and will get +1 score for ...
Sanjay Varyani's user avatar
1vote
1answer
1kviews

HackerRank - Climbing the Leaderboard: I don't understand why my code is exceeding the time limit

Climbing the Leaderboard An arcade game player wants to climb to the top of the leaderboard and track their ranking. The game uses Dense Ranking, so its leaderboard works like this: The player with ...
No Name's user avatar

153050per page
close